import { supplerList } from '@api/m_mall_web_v1.js';
export default class {
  constructor(fetcher) {
    this.fetcher = fetcher;
    this.base = '/m-mall-center';
  }
  /**
   * 查询供应商列表
   * @method
   * @name SupplierOrderV1ApiPOST
   * @param {object} parameters - method options and parameters
   * @param {string} parameters.authorization - Authorization验证
   * @param {} parameters.query - query
   */
  async SupplierOrderV1ApiPOST(parameters) {
    if (parameters === undefined) {
      parameters = {};
    }
    let body = {};
    let queryParameters = {};
    let url = '/api/v1/ccOrder/supplerList';

    if (parameters['query'] !== undefined) {
      body = parameters['query'];
    }

    if (parameters['query'] === undefined) {
      throw new Error('Missing required  parameter: query');
    }

    let result = await this.fetcher({
      method: 'POST',
      baseURL: this.base,
      url,
      data: body,
      params: queryParameters
    });
    return result.data.payload;
  }
  /**
   * 根据供应商查询合同列表
   * @method
   * @name ContractOrderV1ApiPOST
   * @param {object} parameters - method options and parameters
   * @param {string} parameters.authorization - Authorization验证
   * @param {} parameters.query - query
   */
  async ContractOrderV1ApiPOST(parameters) {
    if (parameters === undefined) {
      parameters = {};
    }
    let url = '/api/v1/ccOrder/contractList';
    let body = {};
    let queryParameters = {};

    if (parameters['query'] !== undefined) {
      body = parameters['query'];
    }

    if (parameters['query'] === undefined) {
      throw new Error('Missing required  parameter: query');
    }

    let result = await this.fetcher({
      method: 'POST',
      baseURL: this.base,
      url,
      data: body,
      params: queryParameters
    });

    return result.data.payload;
  }
}
